package com.xc.controller;

import com.xc.model.dto.ResultDTO;
import com.xc.service.FenleiService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/fenlei")
public class FenleiController {
    @Autowired
    private FenleiService fenleiService;

    @GetMapping
    public ResultDTO fenlei() {
        return fenleiService.getFenlei();
    }
    @GetMapping("/new")
    public ResultDTO fenleiNew() {
        return fenleiService.getFenleiNew();
    }
}
